package com.hotel.couponsystem.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.hotel.couponsystem.pojo.CouponStock;

import java.util.List;

/**
 * (CouponStock)表服务接口
 *
 * @author makejava
 * @since 2022-09-30 15:32:29
 */
public interface CouponStockService extends IService<CouponStock> {
    // 根据优惠券编号注销优惠券记录
    Boolean removeByCouponNo(Integer couponNo);
    // 根据优惠券编号查询记录
    CouponStock getByCouponNo(Integer couponNo);

    // 条件查询
    List<CouponStock> getListByCondition(String couponName, String couponNo, String couponStatusNo);
    // 根据优惠券适用方编号查询
    List<CouponStock> getListCouponByHotelNo(Integer hotleNo);
    // 修改优惠券库存量
    String reduceCouponStock(String couponNo);

    //  优惠券的分页查询
    IPage<CouponStock> selectByPage(Integer currentPage,Integer pageSize);
}
